/*
============================================================================
Name        : LuaUIDocument.h
Author      : Jian
Version     :
Copyright   : Jian
Description : Application document class (model)
============================================================================
*/

#ifndef __LUAUIDOCUMENT_H__
#define __LUAUIDOCUMENT_H__

// INCLUDES
#include <akndoc.h>

// FORWARD DECLARATIONS
class CLuaUIAppUi;
class CEikApplication;


// CLASS DECLARATION

/**
* CLuaUIDocument application class.
* An instance of class CLuaUIDocument is the Document part of the
* AVKON application framework for the LuaUI example application.
*/
class CLuaUIDocument : public CAknDocument
{
public: // Constructors and destructor

    /**
    * NewL.
    * Two-phased constructor.
    * Construct a CLuaUIDocument for the AVKON application aApp
    * using two phase construction, and return a pointer
    * to the created object.
    * @param aApp Application creating this document.
    * @return A pointer to the created instance of CLuaUIDocument.
    */
    static CLuaUIDocument* NewL( CEikApplication& aApp );

    /**
    * NewLC.
    * Two-phased constructor.
    * Construct a CLuaUIDocument for the AVKON application aApp
    * using two phase construction, and return a pointer
    * to the created object.
    * @param aApp Application creating this document.
    * @return A pointer to the created instance of CLuaUIDocument.
    */
    static CLuaUIDocument* NewLC( CEikApplication& aApp );

    /**
    * ~CLuaUIDocument
    * Virtual Destructor.
    */
    virtual ~CLuaUIDocument();

public: // Functions from base classes

    /**
    * CreateAppUiL
    * From CEikDocument, CreateAppUiL.
    * Create a CLuaUIAppUi object and return a pointer to it.
    * The object returned is owned by the Uikon framework.
    * @return Pointer to created instance of AppUi.
    */
    CEikAppUi* CreateAppUiL();

private: // Constructors

    /**
    * ConstructL
    * 2nd phase constructor.
    */
    void ConstructL();

    /**
    * CLuaUIDocument.
    * C++ default constructor.
    * @param aApp Application creating this document.
    */
    CLuaUIDocument( CEikApplication& aApp );

};

#endif // __LUAUIDOCUMENT_H__

// End of File
